package com.fsy.entities;

import com.alibaba.excel.annotation.ExcelIgnore;
import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.ContentRowHeight;
import com.alibaba.excel.annotation.write.style.HeadRowHeight;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;

/**
 * @ProjectName: CRMProject
 * @Package: com.sxl.domain
 * @Author songxueliang
 * @Date 2022/5/2 15:56
 */
@Data
@HeadRowHeight(value = 35)
@ContentRowHeight(value = 25)
public class Netfollows_export implements Serializable {
    @ExcelProperty({"跟踪信息", "编号"})
    private Integer id;

    @ExcelProperty({"跟踪信息", "学生编号"})
    private Integer studentId;

    @ExcelProperty({"跟踪信息", "学生姓名"})
    private String studentName;

    @ExcelProperty({"跟踪信息", "跟踪时间"})
    private Date followTime;

    @ExcelProperty({"跟踪信息", "下次跟踪时间"})
    private Date nextFollowTime;

    @ExcelProperty({"跟踪信息", "内容"})
    private String content;

    @ExcelProperty({"跟踪信息", "跟踪者用户ID"})
    private Integer userId;
    @ExcelProperty({"跟踪信息", "跟踪者用户名"})
    private String userName;

    @ExcelIgnore
    private Integer followType;
    //跟踪类型--1-电话跟踪|2-QQ跟踪|3-微信跟踪
    @ExcelProperty({"跟踪信息", "跟踪类型"})
    private String followTypeName;

    public String getFollowTypeName() {
        if (followType==1){
            return followTypeName="电话跟踪";
        }else if (followType==2){
            return followTypeName="QQ跟踪";
        }else {
            return followTypeName="微信跟踪";
        }
    }

    @ExcelProperty({"跟踪信息", "创建时间"})
    private String createTime;

    @ExcelIgnore
    private Integer followState;
    //跟踪状态1-已付款 2-正在跟踪 3-失败
    @ExcelProperty({"跟踪信息", "跟踪状态"})
    private String followStateName;

    public String getFollowStateName() {
        if (followState==1){
            return followStateName="已付款";
        }else if (followState==2){
            return followStateName="正在跟踪";
        }else {
            return followStateName="失败";
        }
    }

}
